package com.hmsproject.datastructures.comparators;

import java.util.Comparator;

import com.hmsproject.datastructures.Hotel;

public class HotelNameComparatorDescending implements Comparator<Hotel> {
	
	private static HotelNameComparatorDescending hotelNameComparatorDescending = new HotelNameComparatorDescending();

	@Override
	public int compare(Hotel hotel1, Hotel hotel2) {
		return hotel2.getName().compareTo(hotel1.getName());
	}
	
	private HotelNameComparatorDescending(){
		
	}
	
	public static HotelNameComparatorDescending getInstance(){
		return hotelNameComparatorDescending;
	}	

}
